﻿<ion-view view-title="我的钱包" cache-view="true" ng-init="init()">
  <ion-nav-buttons side="right">
    <button class="button" ng-click="toHistory()">钱包记录</button>
  </ion-nav-buttons>
  <ion-content style="padding:10px;text-align:center" ng-class="(showstep === 2)?'':'gray_back'">
    <section ng-show="showstep === 0">  
      <IMG width="50%" src="img/coin.jpg" style="padding-top:20px"/>
      <DIV style="padding:20px;text-align:center;font-size:25px">余额：{{data.amount}}</DIV>
      <DIV style="padding:20px;text-align:center;font-size:25px" ng-show="data.card_id">已绑定银行卡号：{{data.card_no_disp}}<BR>提现1~3个工作日到账</DIV>
      <div class="btn_box" ng-show="data.card_id">
        <button class="btn_save" ng-click="getBalance(0)">提  现</button>
        <button class="btn_cancel" ng-click="modifycard()">修改卡号</button>
      </div>
      <button class="btn_save" ng-click="getBalance(1)" ng-show="!data.card_id">提  现</button>
    </section>
    <section  ng-show="showstep === 1" style="height: {{wholeheight}}px">
      <section class="cert_guide_list select-bank">
       
        <ul> 
           <li class="arrow" ng-click="toQueryPage(1)" style="border-left: 1px solid #CCC;border-right: 1px solid #CCC">
            <h4>省&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;份:&nbsp;&nbsp;</h4>
            <span>{{data.province}}</span>
            <!--<input placeholder="请选择省份" readonly="readonly" ng-model="data.province"/>-->
          </li>
           <li class="arrow" ng-click="toQueryPage(2)" style="border-left: 1px solid #CCC;border-right: 1px solid #CCC">
            <h4>城&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;市:&nbsp;&nbsp;</h4>
             <span>{{data.city}}</span>
            <!--<input placeholder="请选择城市" readonly="readonly" ng-model="data.city"/>-->
          </li>
           <li style="border-left: 1px solid #CCC;border-right: 1px solid #CCC">
            <h4>开户银行:&nbsp;&nbsp;</h4>
            <input placeholder="如：上海银行临空经济园区支行" ng-model="data.bank_name"/>
          </li>         
          <li style="border-left: 1px solid #CCC;border-right: 1px solid #CCC">
            <h4>银行卡号:&nbsp;&nbsp;</h4>
            <input placeholder="请输入银行卡号" ng-model="data.card_no"/>
          </li>
        </ul>
        <br/>
        <DIV style="font-size: 20px;text-align: left;color: red;">备注：只支持借记卡，持卡人姓名需与注册姓名相同</DIV>
        <button class="btn_save" ng-click="submit()">下一步</button>
      </section>
    </section>
    <section ng-show="showstep === 2" style="height: {{wholeheight}}px;">
      <section class="truck_line track_line-edit fill_info">        
        <ul>   
          <li style="border-left: 1px solid #CCC;border-right: 1px solid #CCC">
            <h4>省&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;份:&nbsp;&nbsp;</h4>
            <span  style="float: left">{{data.province}}</span>
            <!--<input placeholder="请选择省份" readonly="readonly" ng-model="data.province"/>-->
          </li>
           <li  style="border-left: 1px solid #CCC;border-right: 1px solid #CCC">
            <h4>城&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;市:&nbsp;&nbsp;</h4>
             <span style="float: left">{{data.city}}</span>
            <!--<input placeholder="请选择城市" readonly="readonly" ng-model="data.city"/>-->
          </li>
           <li style="border-left: 1px solid #CCC;border-right: 1px solid #CCC">
            <h4>开户银行:&nbsp;&nbsp;</h4>
             <span style="float: left">{{data.bank_name}}</span>
          </li>       
          <li style="border-left: 1px solid #CCC;border-right: 1px solid #CCC">
            <h4>提现金额:</h4>
            <input placeholder="请输入提现金额" ng-model="data.amount"/>
          </li>
        </ul>
        <button class="btn_save" ng-click="submit()">下一步</button>
      </section>
    </section>
    <section ng-show="showstep === -1" style="height: {{wholeheight}}px">
      <section class="truck_line track_line-edit fill_info">
        <div style="padding:10px;text-align:center;font-size:15px">请输入身份证后六位，字母以*代替</div>
        <div ng-style="pwdoutstyle">
          <div ng-style="onepwdstyle">{{data.digits[0]?'*':''}}</div>
          <div ng-style="onepwdstyle">{{data.digits[1]?'*':''}}</div>
          <div ng-style="onepwdstyle">{{data.digits[2]?'*':''}}</div>
          <div ng-style="onepwdstyle">{{data.digits[3]?'*':''}}</div>
          <div ng-style="onepwdstyle">{{data.digits[4]?'*':''}}</div>
          <div ng-style="lastpwdstyle">{{data.digits[5]?'*':''}}</div>
        </div>
        <div style="height: {{wholeheight - wholewidth - 40}}px">
        </div>
        <div ng-style="pwdkeyoutstyle">
          <div ng-style="onepwdkeystyle" ng-click="inputdigit(1)">1</div>
          <div ng-style="onepwdkeystyle" ng-click="inputdigit(2)">2</div>
          <div ng-style="lastpwdkeystyle" ng-click="inputdigit(3)">3</div>
        </div>
        <div ng-style="pwdkeyoutstyle">
          <div ng-style="onepwdkeystyle" ng-click="inputdigit(4)">4</div>
          <div ng-style="onepwdkeystyle" ng-click="inputdigit(5)">5</div>
          <div ng-style="lastpwdkeystyle" ng-click="inputdigit(6)">6</div>
        </div>
        <div ng-style="pwdkeyoutstyle">
          <div ng-style="onepwdkeystyle" ng-click="inputdigit(7)">7</div>
          <div ng-style="onepwdkeystyle" ng-click="inputdigit(8)">8</div>
          <div ng-style="lastpwdkeystyle" ng-click="inputdigit(9)">9</div>
        </div>
        <div ng-style="pwdkeylastoutstyle">
          <div ng-style="onepwdkeystyle" ng-click="inputdigit('*')">*</div>
          <div ng-style="onepwdkeystyle" ng-click="inputdigit('0')">0</div>
          <div ng-style="lastpwdkeystyle" ng-click="backspace()">退格</div>
        </div>

      </section>   

    </section>
    
  </ion-content>
  <section style="position: absolute;    bottom: 10px;    left: 42%;    right: 42%;">
      <div>
         <ul>   
          <li >
            <a href="javascript:void(0)" ng-click="toInfo()" style="text-decoration:underline">提现说明</a>
          </li>
        </ul>
      </div>
    </section>
</ion-view>